<!DOCTYPE HTML>
<html>

<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <meta name="keywords" content="" />
    <meta name="description" content="" />
    <title>welcome</title>
    <!--[if lt IE 9]>
    <script type="text/javascript" src="__PUBLIC__/js/html5.js"></script>
    <script type="text/javascript" src="__PUBLIC__/js/respond.min.js"></script>
    <script type="text/javascript" src="__PUBLIC__/js/PIE_IE678.js"></script>
    <![endif]-->
    <link href="__PUBLIC__/css/core.css" rel="stylesheet" type="text/css" />
    <link href="__PUBLIC__/css/admin.css" rel="stylesheet" type="text/css" />
    <link href="__PUBLIC__/css/font-awesome.min.css" rel="stylesheet">
    <!--[if IE 7]>
    <link rel="stylesheet" href="__PUBLIC__/css/font-awesome-ie7.min.css">
    <![endif]-->
    <script type="text/javascript" src="__PUBLIC__/js/jquery.min.js"></script>
    <script type="text/javascript" src="__PUBLIC__/js/core.js"></script>
    <script type="text/javascript" src="__PUBLIC__/js/admin.js"></script>
    <script type="text/javascript" src="__PUBLIC__/lib/layer/layer.js"></script>
</head>

<body>
    <present name="message">
        <div style="margin: 0 auto;">
            <p style="text-align: center; font-size: 100px; color: #5eb95e;"><i class="icon-ok-sign"></i></p>
            <h3 style="text-align: center"><?php echo($message); ?></h3>
            <input type="hidden" id="href" value="<?php echo($jumpUrl); ?>">
            <p style="text-align: center">窗口自动关闭，等待时间：<b id="wait"><?php $waitSecond=3;echo($waitSecond); ?></b></p>
        </div>
        <else/>
        <div style="margin: 0 auto;">
            <p style="text-align: center; font-size: 100px; color: #dd514c;"><i class="icon-remove-sign"></i></p>
            <h3 style="text-align: center"><?php echo($error); ?></h3>
            <input type="hidden" id="href" value="<?php echo($jumpUrl); ?>">
            <p style="text-align: center">窗口自动关闭，等待时间：<b id="wait"><?php echo($waitSecond); ?></b></p>
        </div>
    </present>
    <script>
    $(function() {

        var wait = $('#wait').get(0);
        //var wait = document.getElementById('wait');
        var href = '<?php echo($jumpUrl); ?>';
        //var href = document.getElementById('href').value;
        var fobj = $('iframe[id^="layui"]', window.parent.document);

        var interval = setInterval(function() {
            var time = --wait.innerHTML;
            if (time <= 0) {
                //location.href = href;
                if (fobj.length > 0) {
                    window.parent.location.reload();
                    layer_close();

                } else {
                    window.location.href = href;
                }
                clearInterval(interval);
            };
        }, 1000);

    });
    </script>
</body>

</html>
